-
Notifications
You must be signed in to change notification settings - Fork 338
Migrate to edition 2021 #967
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Migrate to edition 2021 #967
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #967 +/- ##
==========================================
- Coverage 94.38% 93.65% -0.74%
==========================================
Files 48 50 +2
Lines 6665 6323 -342
==========================================
- Hits 6291 5922 -369
- Misses 374 401 +27 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
I added some marginal changes:
@jswrenn |
24cbf39 to
c9d0aef
Compare
|
jswrenn
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me; I'll let you hit 'Merge' when you're ready to do so.
| //! | ||
| //! This version of itertools requires Rust 1.63.0 or later. | ||
| //! This version of itertools requires Rust | ||
| #![doc = env!("CARGO_PKG_RUST_VERSION")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Huge fan of this!
|
@Philippe-Cholet is this good to merge? |
|
haha, it's been nearly ten months since the 2024 Edition was released. Maybe we can migrate a bit more |
Edition 2021 requires rustc 1.56+ so it's possible. 1. `cargo fix --edition` 2. Field "edition" updated in "Cargo.toml".
I noted some months ago that the environment variable CARGO_PKG_RUST_VERSION was publicized in 1.63.0 and that if we do not go back before 1.63 then we can automate the MSRV there. Remain "ci.yml" but I don't see a way to automate it, even with `cargo metadata --no-deps --format-version=1 | jq -r '.packages[0].version'`.
`clippy::uninlined_format_args` and 2 more.
8181f3f to
fde1ad9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @Philippe-Cholet
@jswrenn I think we should merge this. It improves the code quite a bit.
I noted 5 months ago that edition 2021 requires rustc 1.56+ so it's now possible.
Is there any reason to not update?